QuickTime 3 Reference

Previous | Chapter Top | Chapter Contents | Next

Synthesizer Knob ID Constants

These constants specify knob IDs for the QuickTime music synthesizer. These constants are all of the form kQTMSKnob ID . For example, kQTMSKnobVolumeLFODelayID is the ID constant for the VolumeLFODelay knob.

enum {
    kQTMSKnobEnv1AttackTimeID           = 0x02000027,
    kQTMSKnobEnv1DecayTimeID            = 0x02000028,
    kQTMSKnobEnv1ExpOptionsID           = 0x0200002D,
    kQTMSKnobEnv1ReleaseTimeID          = 0x0200002C,
    kQTMSKnobEnv1SustainInfiniteID      = 0x0200002B,
    kQTMSKnobEnv1SustainLevelID         = 0x02000029,
    kQTMSKnobEnv1SustainTimeID          = 0x0200002A,
    kQTMSKnobEnv2AttackTimeID           = 0x0200002E,
    kQTMSKnobEnv2DecayTimeID            = 0x0200002F,
    kQTMSKnobEnv2ExpOptionsID           = 0x02000034,
    kQTMSKnobEnv2ReleaseTimeID          = 0x02000033,
    kQTMSKnobEnv2SustainInfiniteID      = 0x02000032,
    kQTMSKnobEnv2SustainLevelID         = 0x02000030,
    kQTMSKnobEnv2SustainTimeID          = 0x02000031,
    kQTMSKnobExclusionGroupID           = 0x0200001C,
    kQTMSKnobFilterFrequencyEnvelopeDepthID
                                        = 0x0200003B,
    kQTMSKnobFilterFrequencyEnvelopeID  = 0x0200003A,
    kQTMSKnobFilterKeyFollowID          = 0x02000037,
    kQTMSKnobFilterQEnvelopeDepthID     = 0x0200003D,
                                        /* reverb threshhold */
    kQTMSKnobFilterQEnvelopeID          = 0x0200003C,
    kQTMSKnobFilterQID                  = 0x02000039,
    kQTMSKnobFilterTransposeID          = 0x02000038,
    kQTMSKnobLastIDPlus1                = 0x0200003F
    kQTMSKnobPitchEnvelopeDepthID       = 0x02000036, /* filter */
    kQTMSKnobPitchEnvelopeID            = 0x02000035,
    kQTMSKnobPitchLFODelayID            = 0x02000013,
    kQTMSKnobPitchLFODepthFromWheelID   = 0x02000025,
                                        /* volume nnv again */
    kQTMSKnobPitchLFODepthID            = 0x02000017,
    kQTMSKnobPitchLFOOffsetID           = 0x0200001B,
    kQTMSKnobPitchLFOPeriodID           = 0x02000015,
    kQTMSKnobPitchLFOQuantizeID         = 0x02000018,
                                        /* stereo related knobs */
    kQTMSKnobPitchLFORampTimeID         = 0x02000014,
    kQTMSKnobPitchLFOShapeID            = 0x02000016,
    kQTMSKnobPitchSensitivityID         = 0x02000023,
    kQTMSKnobPitchTransposeID           = 0x02000012,
                                        /* sample can override */
    kQTMSKnobReverbThresholdID          = 0x0200003E,
    kQTMSKnobStartID                    = 0x02000000,
    kQTMSKnobStereoDefaultPanID         = 0x02000019,
    kQTMSKnobStereoPositionKeyScalingID = 0x0200001A,
    kQTMSKnobSustainInfiniteID          = 0x0200001E,
    kQTMSKnobSustainTimeID              = 0x0200001D,
    kQTMSKnobVelocityHighID             = 0x02000021,
    kQTMSKnobVelocityLowID              = 0x02000020,
    kQTMSKnobVelocitySensitivityID      = 0x02000022,
    kQTMSKnobVolumeAttackTimeID         = 0x02000001,
                                        /* sample can override */
    kQTMSKnobVolumeDecayTimeID          = 0x02000002,
                                        /* sample can override */
    kQTMSKnobVolumeExpOptionsID         = 0x02000026, /* env1 */
    kQTMSKnobVolumeLFODelayID           = 0x02000007,
    kQTMSKnobVolumeLFODepthFromWheelID  = 0x02000024,
    kQTMSKnobVolumeLFODepthID           = 0x0200000B,
    kQTMSKnobVolumeLFOPeriodID          = 0x02000009,
    kQTMSKnobVolumeLFORampTimeID = 0x02000008,
    kQTMSKnobVolumeLFOShapeID           = 0x0200000A,
    kQTMSKnobVolumeLFOStereoID          = 0x0200001F,
    kQTMSKnobVolumeOverallID            = 0x0200000C,
    kQTMSKnobVolumeReleaseKeyScalingID  = 0x02000005,
    kQTMSKnobVolumeReleaseTimeID        = 0x02000006,
                                        /* sample can override */
    kQTMSKnobVolumeSustainLevelID       = 0x02000003,
                                        /* sample can override */
    kQTMSKnobVolumeVelocity127ID        = 0x0200000D,
    kQTMSKnobVolumeVelocity16ID         = 0x02000011,
                                        /* pitch related knobs */
    kQTMSKnobVolumeVelocity32ID         = 0x02000010,
    kQTMSKnobVolumeVelocity64ID         = 0x0200000F,
    kQTMSKnobVolumeVelocity96ID         = 0x0200000E
};

Constant descriptions

kQTMSKnobEnv1AttackTimeID
Specifies the attack time of the first general-purpose envelope. This is the number of milliseconds between the start of a note and the maximum value of the attack.
kQTMSKnobEnv1DecayTimeID
Specifies the decay time of the first general-purpose envelope. This is the number of milliseconds between the time the attack is completed and the envelope level is reduced to the sustain level.
kQTMSKnobEnv1ExpOptionsID
Specifies whether segments of the envelope are treated as exponential curves. Bits 0, 1, 2, and 3 of the knob value specify the interpretation of the attack, decay, sustain, and release segments of the envelope, respectively. If any of these bits is 0, the level of the corresponding segment changes linearly from its initial to final value during the time interval specified by the corresponding envelope time knob. If any of these bits is non-zero, the level of the corresponding segment changes exponentially during the time interval specified by the corresponding envelope time knob. During an exponential decrease the level changes from maximum amplitude (no attenuation) to approximately 1/65536th of maximum amplitude (96 dB of attenuation) during the time interval specified by the corresponding envelope time knob, and afterward the level immediately becomes 0.
kQTMSKnobEnv1ReleaseTimeID
Specifies the release time of the first general-purpose envelope .
kQTMSKnobEnv1SustainInfiniteID
Specifies infinite sustain for the first general-purpose envelope. If the value of this knob is TRUE, the knob overrides the kQTMSKnobEnv1SustainTimeID knob and causes the sustain to last, at undiminished level.
kQTMSKnobEnv1SustainLevelID
Specifies the sustain level of the first general-purpose envelope . This is the percentage of full volume that the sample is initially played at after the decay time has elapsed.
kQTMSKnobEnv1SustainTimeID
Specifies the sustain time of the first general-purpose envelope. This is the number of milliseconds it takes for the sample to soften to 90% of its sustain level. This softening occurs in an exponential fashion, so it never actually reaches complete silence. This is used for instruments like a piano, which gradually soften over time even while the key is held down.
kQTMSKnobEnv2AttackTimeID
Specifies the attack time of the second general-purpose envelope. This is the number of milliseconds between the start of a note and the maximum value of the attack. Percussive sounds usually have zero attack time; gentler sounds may have short attack times. Long attack times are usually used for special effects.
kQTMSKnobEnv2DecayTimeID
Specifies the decay time of the second general-purpose envelope. This is the number of milliseconds between the time the attack is completed and the time the sample is reduced in volume to the sustain level.
kQTMSKnobEnv2ExpOptionsID
Specifies whether segments of the envelope are treated as exponential curves. Bits 0, 1, 2, and 3 of the knob value specify the interpretation of the attack, decay, sustain, and release segments of the envelope, respectively. If any of these bits is 0, the level of the corresponding segment changes linearly from its initial to final value during the time interval specified by the corresponding envelope time knob. If any of these bits is non-zero, the level of the corresponding segment changes exponentially during the time interval specified by the corresponding envelope time knob. During an exponential decrease the level changes from maximum amplitude (no attenuation) to approximately 1/65536th of maximum amplitude (96 dB of attenuation) during the time interval specified by the corresponding envelope time knob, and afterward the level immediately becomes 0.
kQTMSKnobEnv2ReleaseTimeID
Specifies the release time of the second general-purpose envelope . This is the number of milliseconds it takes for the sound to soften down to silence after the key is released.
kQTMSKnobEnv2SustainInfiniteID
Specifies infinite sustain for the second general-purpose envelope. If the value of this knob is TRUE, the knob overrides the kQTMSKnobEnv2SustainTimeID knob and causes the sustain to last, at undiminished volume, until the end of the sample. Instruments like an organ have infinite sustain.
kQTMSKnobEnv2SustainLevelID
Specifies the sustain level of the first general-purpose envelope . This is the percentage of full volume that the sample is initially played at after the decay time has elapsed.
kQTMSKnobEnv2SustainTimeID
Specifies the sustain time of the second general-purpose envelope. This is the number of milliseconds it takes for the sample to soften to 90% of its sustain level. This softening occurs in an exponential fashion, so it never actually reaches complete silence. This is used for instruments like a piano, which gradually soften over time even while the key is held down.
kQTMSKnobExclusionGroupID
Specifies an exclusion group. Within an instrument, no two notes with the same exclusion group number excepting exclusion group zero will ever sound simultaneously.This knob is generally used only as an override knob within a key range. (Note that the key range is not an entire instrument.) It is useful for simulating certain mechanical instruments in which the same mechanism produces different sounds. For example, in a drum kit, the open high hat and the closed high hat are played on the same piece of metal. If you assign both sounds to the same exclusion group, playing a closed high hat sound will immediately silence any currently playing open high hat sounds.
kQTMSKnobFilterFrequencyEnvelopeDepthID
Controls the depth of the envelope for the filter frequency. This is an 8.8 signed fixed point value that specifies the number of semitones the frequency is altered when its envelope (specified by the kQTMSKnobFilterFrequencyEnvelopeID knob) is at maximum amplitude. If the value of the kQTMSKnobFilterFrequencyEnvelopeID knob is 0, which specifies not to use an envelope to affect filter frequency, the kQTMSKnobFilterFrequencyEnvelopeDepthID knob is ignored.
kQTMSKnobFilterFrequencyEnvelopeID
Specifies which of the two general-purpose envelopes to use to affect the filter frequency, or not to use an envelope to affect filter frequency. If the value of this knob is 0, no envelope is used. If the value of this knob is 1 or 2, the corresponding general-purpose envelope is used.
kQTMSKnobFilterKeyFollowID
Specifies how closely the frequency of the filter follows the note being played. The emphasis note is determined by the following formula, expressed in MIDI notes:

= ( - 60) * (kQTMSKnobFilterKeyFollowID / 100) - 60 - kQTMSKnobFilterTransposeID

kQTMSKnobFilterQEnvelopeDepthID
Controls the depth of the envelope for the emphasis ("Q") of the filter. This is an 8.8 signed fixed point value that specifies the emphasis is altered when its envelope (specified by the kQTMSKnobFilterQEnvelopeID knob) is at maximum amplitude. If the value of the kQTMSKnobFilterQEnvelopeID knob is 0, which specifies not to use an envelope to affect filter frequency, the kQTMSKnobFilterQEnvelopeDepthID knob is ignored.
kQTMSKnobFilterQEnvelopeID
Specifies which of the two general-purpose envelopes to use to affect the emphasis ("Q") of the filter, or not to use an envelope to affect the emphasis. If the value of this knob is 0, no envelope is used. If the value of this knob is 1 or 2, the corresponding general-purpose envelope is used.
kQTMSKnobFilterQID
Specifies the emphasis ("Q") of the filter. The value must be in the range 0 to 65536, inclusive, where 0 specifies no emphasis and disables the filter, and 65536 specifies relatively steep emphasis, but not so steep that it approaches feedback.
kQTMSKnobFilterTransposeID
Specifies a transposition, in semitones, of the frequency of the filter. The emphasis note is determined by the following formula:

= ( - 60) * (kQTMSKnobFilterKeyFollowID / 100) - 60 - kQTMSKnobFilterTransposeID

kQTMSKnobPitchEnvelopeDepthID
Specifies the depth of the pitch envelope. This is an 8.8 signed fixed point value that specifies the number of semitones the pitch is altered when the envelope for the pitch (specified by the kQTMSKnobPitchEnvelopeID knob) is at maximum amplitude. If the value of the kQTMSKnobPitchEnvelopeID knob is 0, which specifies not to use an envelope to affect pitch, the kQTMSKnobPitchEnvelopeDepthID knob is ignored.
kQTMSKnobPitchEnvelopeID
Specifies which of the two general-purpose envelopes to use to affect pitch, or not to use an envelope to affect pitch. If the value of this knob is 0, no envelope is used. If the value of this knob is 1 or 2, the corresponding general-purpose envelope is used to affect pitch.
kQTMSKnobPitchLFODelayID
Specifies the delay for the pitch LFO. This is the number of milliseconds before the LFO takes effect.
kQTMSKnobPitchLFODepthFromWheelID
Specifies the extent to which a synthesizer's modulation wheel (or the MIDI messages it generates) controls the depth of the pitch LFO. The value of this knob is multiplied by the modulation wheel value (a value between 0 to 1), and the result is added to the volume LFO depth specified by the kQTMSKnobPitchLFODepthID knob. Modulation wheel controllers and the MIDI messages they generate are most often used to create vibrato and tremolo effects.
kQTMSKnobPitchLFODepthID
Specifies the depth of the pitch LFO. This is the number of semitones by which the pitch is altered by the LFO. A value of 0 does not change the pitch. A value of 12 changes the pitch from an octave lower to an octave higher, with one exception: if the square up waveform is used for the LFO, the normal pitch is the minimum pitch.
kQTMSKnobPitchLFOOffsetID
Specifies the LFO offset. This is a constant value; the units are 8.8 semitones. It is added to the pitch, and is affected by the LFO delay and LFO ramp-up times. It is similar to transposition but subject to the LFO delay and LFO ramp-up times.
kQTMSKnobPitchLFOPeriodID
Specifies the period for the pitch LFO. This is the wavelength of the LFO in milliseconds. (The LFO rate in Hz is 1000 / kQTMSKnobPitchLFOPeriodID)
kQTMSKnobPitchLFOQuantizeID
To be provided
kQTMSKnobPitchLFORampTimeID
Specifies the LFO ramp-up time. This is the number of milliseconds after the LFO delay that it takes for the LFO to reach full effect.
kQTMSKnobPitchLFOShapeID
Specifies the waveform used for the LFO. The available waveforms are sine, triangle, sawtooth up, sawtooth down, square up, square up-and-down, and random. The sine and triangle shapes both produce a smooth rise and fall of the pitch. The sawtooth up produces a gradual increase in pitch followed by a sudden fall. The sawtooth down shape produces a sudden increase in pitch, followed by a gradual reduction. The square up and square up-and-down shapes apply a sudden pulsing to the pitch; the square up only makes the pitch higher, while the up-and-down variant makes the sound higher and lower. The Random shape applies random changes to the pitch, once per LFO period.
kQTMSKnobPitchSensitivityID
Specifies the pitch key scaling. This determines how much the pitch of the struck note affects the pitch of the played note. Typically, this is 100%, meaning that a change in 1 semitone of the struck note will produce a change in 1 semitone of the played note. Setting this knob to zero will cause every note to play at the same pitch. Setting it to 50% would allow for all notes within the quarter-tone scale (24 notes per octave) to be played.
kQTMSKnobPitchTransposeID
Specifies a transposition for pitches. The value is the number of semitones to transpose; a positive value raises the pitch, while a negative value lowers it. The value can be a real number; the fractional part of the value alters the pitch by an additional fraction of a semitone. For example, to raise the pitch of every note played on the instrument by an octave, set the transpose knob to 12.0.
kQTMSKnobReverbThresholdID
To be provided
kQTMSKnobStereoDefaultPanID
Specifies the default pan position for stereo sound. If no pan controller is applied, this determines where in the stereo field notes for this instrument will be played.
kQTMSKnobStereoPositionKeyScalingID
Specifies the key scaling for stereo sound. Amount to modify the stereo placement of notes based upon pitch. At the highest setting, high pitched notes will be placed completely in the right hand speaker, while low pitched notes will be placed entirely in the left hand speaker.
kQTMSKnobSustainInfiniteID
Specifies infinite sustain for the volume envelope. If the value of this knob is TRUE, the knob overrides the kQTMSKnobSustainTimeID knob and causes the sustain to last, at undiminished volume, until the end of the sample. Instruments like an organ have infinite sustain.
kQTMSKnobSustainTimeID
Specifies the sustain time of the volume envelope. This is the number of milliseconds it takes for the note to soften to 90% of its sustain level. This softening occurs in an exponential fashion, so it never actually reaches complete silence. This is used for instruments like a piano, which gradually soften over time even while the key is held down.
kQTMSKnobVelocityHighID
Specifies the maximum velocity value that will produce sound for a particular note. If the velocity value is greater, the note does not sound. This can be used to assign different samples to be played for selected velocity ranges.
kQTMSKnobVelocityLowID
Specifies the minimum velocity value that will produce sound for a particular note. If the velocity value is less, the note does not sound. This can be used to assign different samples to be played for selected velocity ranges.
kQTMSKnobVelocitySensitivityID
Specifies velocity sensitivity, which determines how much the key velocity affects the volume of the note. This value is a percentage. At 100%, a velocity of 1 is nearly silent, and a velocity of 127 is full volume. At 50%, the volume range is from one fourth to three fourths. At 0%, any velocity of key strike will produce a half volume note. If the value of this knob is negative, then the note will play more softly as the key is struck harder.
kQTMSKnobVolumeAttackTimeID
Specifies the attack time for the volume envelope. This is the number of milliseconds between the start of a note and maximum volume. Percussive sounds usually have zero attack time; gentler sounds may have short attack times. Long attack times are usually used for special effects.
kQTMSKnobVolumeDecayTimeID
Specifies the decay time for the volume envelope. This is the number of milliseconds between the time the attack is completed and the time the volume is reduced to the sustain level.
kQTMSKnobVolumeExpOptionsID
Specifies whether segments of the volume envelope are treated as exponential curves. Bits 0, 1, 2, and 3 of the knob value specify the interpretation of the attack, decay, sustain, and release segments of the volume envelope, respectively. If any of these bits is 0, the volume level of the corresponding segment changes linearly from its initial to final value during the time interval specified by the corresponding envelope time knob. If any of these bits is non-zero, the volume level of the corresponding segment changes exponentially during the time interval specified by the corresponding envelope time knob. During an exponential decrease the volume level changes from full volume (no attenuation) to approximately 1/65536th of full volume (96 dB of attenuation) during the time interval specified the corresponding envelope time knob, and afterward the volume level immediately becomes 0.
kQTMSKnobVolumeLFODelayID
Specifies the delay for the volume LFO. This is the number of milliseconds before the LFO takes effect.
kQTMSKnobVolumeLFODepthFromWheelID
Specifies the extent to which a synthesizer's modulation wheel (or the MIDI messages it generates) controls the depth of the volume LFO. The value of this knob is multiplied by the modulation wheel value (a value between 0 to 1), and the result is added to the volume LFO depth specified by the kQTMSKnobVolumeLFODepthID knob. Modulation wheel controllers and the MIDI messages they generate are most often used to create vibrato and tremolo effects.
kQTMSKnobVolumeLFODepthID
Specifies the depth of the volume LFO. This is the amount, expressed as a percentage, by which the volume is altered by the LFO. A value of 0 does not change the volume. A value of 100 changes the volume from complete silence to twice the volume specified by the envelope, with one exception: if the square up waveform is used for the LFO, the normal envelope volume is the minimum volume.
kQTMSKnobVolumeLFOPeriodID
Specifies the period for the volume LFO. This is the wavelength of the LFO in milliseconds. (The LFO rate in Hz is 1000 / kQTMSKnobPitchLFOPeriodID)
kQTMSKnobVolumeLFORampTimeID
Specifies the ramp-up time for the volume LFO. This is the number of milliseconds after the LFO delay has elapsed that it takes for the LFO to reach full effect.
kQTMSKnobVolumeLFOShapeID
Specifies the waveform used for the LFO. The available waveforms are sine, triangle, sawtooth up, sawtooth down, square up, square up-and-down, and random. The sine and triangle shapes both produce a smooth rise and fall of the volume. The sawtooth up produces a gradual increase in volume followed by a sudden fall. The sawtooth down shape produces a sudden increase in volume, followed by a gradual reduction (often heard as a "ting" sound). The square up and square up-and-down shapes apply a sudden pulsing to the volume; the square up only makes the sound louder, while the up-and-down variant makes the sound louder and softer. The Random shape applies random changes to the volume, once per LFO period.
kQTMSKnobVolumeLFOStereoID
If the synthesizer is producing stereo output and the value of this knob is 1, the LFO is applied in phase to one of the stereo channels and 180° out of phase to the other. This often causes a "vibration" effect within the stereo field.
kQTMSKnobVolumeOverallID
Specifies the overall volume of the instrument, in decibels. Increasing the value by 6 doubles the maximum amplitude of the signal, increasing the value by 12 quadruples it, and so on.
kQTMSKnobVolumeReleaseKeyScalingID
Specifies the release time key scaling. Modifies the release time based on the key pitch.
kQTMSKnobVolumeReleaseTimeID
Specifies the release time of the volume envelope . This is the number of milliseconds it takes for the sound to soften down to silence after the key is released.
kQTMSKnobVolumeSustainLevelID
Specifies the sustain level of the volume envelope . This is the percentage of full volume that a note is initially played at after the decay time has elapsed.

© 1997 Apple Computer, Inc.

Previous | Chapter Top | Chapter Contents | Next